package com.web.web;

import com.opensymphony.xwork2.ActionSupport;

public class SessionAction extends ActionSupport {

	private static final long serialVersionUID = 1L;

	private String proxyName;

	private String proxyPassword;

	public String getProxyName() {
		return proxyName;
	}

	public void setProxyName(String proxyName) {
		this.proxyName = proxyName;
	}

	public String getProxyPassword() {
		return proxyPassword;
	}

	public void setProxyPassword(String proxyPassword) {
		this.proxyPassword = proxyPassword;
	}

	public boolean requiresProxy() {
		boolean hasProxyName = proxyName != null && !proxyName.equals("");
		boolean hasProxyValue = proxyPassword != null && !proxyPassword.equals("");

		return hasProxyName && hasProxyValue;
	}

}